package com.wlyuan.open.scanner.utils.enums.quotation;

import com.wlyuan.core.marker.NamedValue;
import com.wlyuan.core.marker.NamedValueMap;
import lombok.AccessLevel;
import lombok.Getter;
import lombok.RequiredArgsConstructor;

import java.util.Map;

/**
 * @author lijing
 * @description 合约模式
 */
@RequiredArgsConstructor(access = AccessLevel.PRIVATE)
@Getter
public enum TemplateMatchModeEnum implements NamedValue<Integer> {

    MANUAL(1, 2, "手动"),
    AUTO(0, 1, "自动"),
    ;

    private final Integer value;
    private final Integer newValue;
    private final String name;


    private static final Map<Integer, TemplateMatchModeEnum> MAP = new NamedValueMap<>(TemplateMatchModeEnum.class);

    public static TemplateMatchModeEnum fromValue(Integer value) {
        return MAP.get(value);
    }


}
